﻿/// <reference path="../jquery/jquery-1.3.2-vsdoc.js" />
/// <reference path="Complaint.Namespaces.js" />
/// <reference path="Complaint.Common.js" />

$(function() {
    $("#categoryTree").tree(
    {
        rules: {
            renameable: "none",
            deletable: "none",
            creatable: "none",
            multiple: "ctrl"
        },
        lang: {
            loading: "Loading ..."
        },
        ui: {
            context: [
                {
                    visible: function(NODE, TREE_OBJ) {
                        return -1;
                    }
                }
            ]
        }
    });

    $("#expand").click(function(evt) {
        evt.preventDefault();
        $.tree_reference("categoryTree").open_all();
    });

    $("#collapse").click(function(evt) {
        evt.preventDefault();
        $.tree_reference("categoryTree").close_all();
    });

});